﻿using Deferred.Library.Scene;
using Microsoft.Xna.Framework;

namespace Deferred.Editor.Scene
{
    public class TerrainWrapper
    {
        public Terrain Terrain { get; private set; }

        public float ScaleX { get { return Terrain.GenerationData.Scale.X; } set { Terrain.GenerationData.Scale = new Vector3(value, Terrain.GenerationData.Scale.Y, Terrain.GenerationData.Scale.Z); } }
        public float ScaleY { get { return Terrain.GenerationData.Scale.Y; } set { Terrain.GenerationData.Scale = new Vector3(Terrain.GenerationData.Scale.X, value, Terrain.GenerationData.Scale.Z); } }
        public float ScaleZ { get { return Terrain.GenerationData.Scale.Z; } set { Terrain.GenerationData.Scale = new Vector3(Terrain.GenerationData.Scale.X, Terrain.GenerationData.Scale.Y, value); } }

        public float PositionX { get { return Terrain.Position.X; } set { Terrain.Position = new Vector3(value, Terrain.Position.Y, Terrain.Position.Z); } }
        public float PositionY { get { return Terrain.Position.Y; } set { Terrain.Position = new Vector3(Terrain.Position.X, value, Terrain.Position.Z); } }
        public float PositionZ { get { return Terrain.Position.Z; } set { Terrain.Position = new Vector3(Terrain.Position.X, Terrain.Position.Y, value); } }


        public TerrainWrapper(Terrain terrain)
        {
            Terrain = terrain;
        }
    }
}
